home *** CD-ROM | disk | FTP | other *** search
/ The Games Machine 76 / XENIATGM66.iso / Indiana Jones / Indiana Jones.exe / RESOURCE / PREVIEW.GOB / cog_inf_turnerslast.cog < prev    next >
Text File  |  1999-11-15  |  8KB  |  237 lines

  1. # Jones 3D Cog Script
  2. #
  3. # INF_TurnersLast.cog
  4. #
  5. # [SXC]
  6. #
  7. # (C) 1998 LucasArts Entertainment Co. All Rights Reserved
  8. # ========================================================================================
  9.  
  10. symbols
  11.  
  12.     message     startup
  13.     message     crossed
  14.    
  15.     thing       player                                  local
  16.     thing       indyactor
  17.     
  18.     thing       turner
  19.     sound        pow=imp2_activate.wav                    local
  20.     
  21.     surface     croschek
  22.     
  23.     thing       intro_in_mk_1
  24.     thing       actor_sight1
  25.     thing       turner_mk_1
  26.     thing       turner_sight_1
  27.     thing       sophtarget
  28.     
  29.     thing       cut0_tgt0
  30.     thing       cut0_cam0
  31.     thing       cut0_tgt1
  32.     thing       cut0_cam1
  33.     thing       cut0_tgt2
  34.     thing       cut0_cam2
  35.     thing       cut1_tgt0
  36.     thing       cut1_cam0
  37.     thing       cut2_tgt0
  38.     thing       cut2_cam0
  39.     
  40.     sound       indyline0=im06j01.wav                   local
  41.     sound       turnerline0=im06t02.wav                 local
  42.     sound       indyline1=im06j03.wav                   local
  43.     sound       turnerline1=im06t04.wav                 local
  44.     sound       indyline2=im06j05.wav                   local
  45.     sound       turnerline2=im06t06.wav                 local
  46.     sound       sophialine=im03s21.wav                  local
  47.     
  48.     keyframe    in_ltarmup=0in_leftarm_1_1.key            local
  49.     keyframe    in_crossArms=0in_stand1_bd_2.key           local
  50.     keyframe    in_activate=in_activate_medium.key        local
  51.     keyframe    in_Smash=0in_smash_1_4.key                local
  52.     keyframe    in_handsONhips=0in_stand4.key            local
  53.     keyframe    in_sideTOhips=0in_stand1_bd_4.key       local
  54.     
  55.     keyframe    trn_handships=0tu_stand1.key            local
  56.     keyframe    tu_rthand_1_1=0tu_righthnd_1_1.key        local
  57.     keyframe    trn_fistshake=0tu_pointout_1_1.key        local
  58.     keyframe    trn_nothelp=0tu_nothelp_1_1.key            local
  59.     keyframe    trn_reach=0tu_reach_1_1.key                local
  60.     
  61.     flex        in_headRate                                local
  62.     flex        in_rotRate                                local
  63.     
  64.     int         curline                                 local
  65.     int         croschek=0                              local
  66.     int         tu_keyTrack1                            local
  67.     int         in_keyTrack1                            local
  68.     int         crosit=0                                local
  69.     
  70.     cog         huntcog
  71.     
  72.     model          mod_tu_imp2=hand_tu_imp2_b.3do            local
  73.     
  74. end
  75.  
  76. code
  77.  
  78. # ========================================================================================
  79. startup:
  80.  
  81.     player = GetLocalPlayerThing();
  82.     ClearThingFlags(turner, 0x80000);
  83.     ThingFadeAnim(turner, 1.0, 0.0, 0.1, 0);
  84.     AISetCutsceneMode(turner);
  85.     SetThingMesh(turner, 8, mod_tu_imp2, 0);
  86.     
  87. return;
  88.         
  89. #----------------------------------------------------------------------------------------
  90.  
  91. crossed:
  92.  
  93.     If ((GetSenderRef() == croschek) && (crosit == 1)) return;
  94.     //start cutscene
  95.     crosit=1;
  96.     MakeMeStop();
  97.     StartCutscene(1);
  98.     CopyPlayerHolsters(player, indyactor);
  99.     SetThingFlags(player, 0x80000);
  100.     ClearThingFlags(indyactor, 0x80000);
  101.     
  102.     //Prep actor and move him to 1st mark...
  103.     AISetCutsceneMode(indyactor);
  104.     in_headRate = GetThingMaxHeadVel(player);
  105.     SetThingMaxHeadVel(indyactor, 200.0);
  106.     in_rotRate = GetThingMaxRotVel(player);
  107.     SetThingMaxRotVel(indyactor, 200.0);
  108.     AISetMoveSpeed(indyactor, 1.0);
  109.     AISetMoveThing(indyactor, intro_in_mk_1, 0);
  110.     AISetLookThing(indyactor, actor_sight1);
  111.     
  112.     //CUT to Wide shot of door watching indy walk in
  113.     SetCameraSecondaryFocus(2, cut0_tgt0);
  114.     SetCameraFocus(2, cut0_cam0);
  115.     SetCurrentCamera(2);
  116.     SetCameraFOV(90, 0, 0);
  117.     Sleep(1);
  118.     AIWaitForStop(indyactor);
  119.     
  120.     //PAN to the left and PAN focus to right
  121.     SetCameraLookInterp(2, 1);
  122.     SetCameraPosInterp(2, 1);
  123.     SetCameraInterpSpeed(2, 2);
  124.     Sleep(0.5);
  125.     SetCameraSecondaryFocus(2, cut0_tgt1);
  126.     AttachThingToThing(cut0_tgt1, turner);
  127.     SetCameraFocus(2, cut0_cam1);
  128.     SetCameraFOV(80, 1, 2);
  129.     
  130.     //start Turner fade in
  131.     ThingFadeAnim(turner, 0.0, 1.0, 1.0, 0);
  132.     AISetLookThing(indyactor, turner);
  133.     MakeFairyDust(turner, GetThingJointPos(turner, 5));
  134.     PlaySoundThing(pow, turner, 1, 10, 20, 0);
  135.     Sleep(0.5);
  136.     MakeFairyDust(turner, GetThingJointPos(turner, 5));
  137.     Sleep(0.5);
  138.     MakeFairyDust(turner, GetThingJointPos(turner, 5));
  139.     Sleep(0.5);
  140.     
  141.     //INDY: "Turner you've got the part I need. Hand it over"
  142.     curline = PlayVoice(indyactor, indyline0, 1, 0);
  143.     PlayKey(indyactor, in_ltarmup, 4, 0x12, 1);
  144.     PlayKey(indyactor, in_activate, 4, 0x12, 1);
  145.     WaitForSound(curline);
  146.     
  147.     //TURNER: "Sorry I cant do that"
  148.     SetCameraFocus(2, cut0_cam2);
  149.     curline = PlayVoice(turner, turnerline0, 1, 0);
  150.     AISetMoveSpeed(turner, 2.0);
  151.     AISetMoveThing(turner, turner_mk_1, 1);
  152.     AISetLookThing(turner, turner_sight_1);
  153.     AIWaitForStop(turner);
  154.     tu_keyTrack1 = PlayKey(turner, trn_handships, 2, 0x10, 0);
  155.     PlayKey(turner, tu_rthand_1_1, 4, 0x12, 0);
  156.     WaitForSound(curline);
  157.     
  158.     //INDY: "Come on it's our only chance to save Sophia"
  159.     curline = PlayVoice(sophtarget, sophialine, 1, 0);
  160.     SetCameraSecondaryFocus(2, cut0_tgt2);
  161.     SetCameraFOV(70, 1, 2);
  162.     WaitForSound(curline);
  163.     PlayVoice(indyactor, indyline1, 1, 1);
  164.     
  165.     //TURNER: "You dont fool me Jones..."
  166.     in_keyTrack1 = PlayKey(indyactor, in_handsONhips, 2, 0x10, 0);
  167.     PlayKey(indyactor, in_sideTOhips, 4, 0x12, 0);
  168.     SetCameraLookInterp(2, 0);
  169.     SetCameraPosInterp(2, 0);
  170.     SetCameraInterpSpeed(2, 0);
  171.     Sleep(0.25);
  172.     curline = PlayVoice(turner, turnerline1, 1, 0);
  173.     SetCameraSecondaryFocus(2, cut1_tgt0);
  174.     SetCameraFocus(2, cut1_cam0);
  175.     SetCurrentCamera(2);
  176.     SetCameraFOV(40, 1, 6);
  177.     PlayKey(turner, trn_nothelp, 4, 0x12, 1);
  178.     PlayKey(turner, trn_reach, 4, 0x12, 1);
  179.     Sleep(1.5);
  180.     PlayKey(turner, trn_fistshake, 4, 0x12, 1);
  181.     WaitForSound(curline);
  182.     
  183.     //INDY: "The world's seen enough dictators..."
  184.     curline = PlayVoice(indyactor, indyline2, 1, 0);
  185.     SetCameraSecondaryFocus(2, cut2_tgt0);
  186.     SetCameraFocus(2, cut2_cam0);
  187.     SetCurrentCamera(2);
  188.     PlayKey(indyactor, in_Smash, 4, 0x12, 0);
  189.     SetCameraFOV(70, 0, 0);
  190.     SetCameraFOV(45, 1, 2);
  191.     WaitForSound(curline);
  192.     StopKey(indyactor, in_keyTrack1, 0.5);
  193.     
  194.     
  195.     //TURNER: "You'll never get away with it..."
  196.     curline = PlayVoice(turner, turnerline2, 1, 0);
  197.     SetCameraSecondaryFocus(2, cut1_tgt0);
  198.     SetCameraFocus(2, cut1_cam0);
  199.     SetCameraFOV(70, 0, 0);
  200.     SetCameraFOV(90, 1, 2);
  201.     ThingFadeAnim(turner, 1.0, 0.0, 1.0, 0);
  202.     StopKey(turner, tu_keyTrack1, 0.5);
  203.     MakeFairyDust(turner, GetThingJointPos(turner, 5));
  204.     PlaySoundThing(pow, turner, 1, 10, 20, 0);
  205.     Sleep(0.5);
  206.     MakeFairyDust(turner, GetThingJointPos(turner, 5));
  207.     Sleep(0.5);
  208.     MakeFairyDust(turner, GetThingJointPos(turner, 5));
  209.     WaitForSound(curline);
  210.     Sleep(1);
  211.     DestroyThing(turner);
  212.     
  213.     //Restore Everything
  214.     CopyOrientAndPos(indyactor, player);
  215.     SetCameraLookInterp(2, 0);
  216.     SetCameraPosInterp(2, 0);
  217.     SetCameraInterpSpeed(2, 0);
  218.     Sleep(0.01);
  219.     ClearThingFlags(player, 0x80000);
  220.     SetThingMaxHeadVel(indyactor, in_headRate);
  221.     SetThingMaxRotVel(indyactor, in_rotRate);
  222.     SetThingFlags(indyactor, 0x80000);
  223.     SetCameraPosition(1, GetThingPos(cut0_cam1));
  224.     SetCurrentCamera(1);
  225.     SetCameraFOV(90, 0, 0);
  226.     Sleep(0.01);
  227.     EndCutscene();
  228.     ClearActorFlags(player, 0x200000);
  229.     
  230.     //SendMessage to TurnerHunt
  231.     SendMessage(huntcog, user0);
  232.     
  233. return;
  234.  
  235. #----------------------------------------------------------------------------------------
  236.     
  237. end